package com.list.data.structure;

import java.util.Hashtable;
import java.util.Iterator;

import com.hp.hpl.jena.rdf.model.Resource;

public class ResourceWeight extends Hashtable<Resource, Double>{
    public ResourceWeight(){
    }
    
    @Override
    public String toString(){
        StringBuffer sb = new StringBuffer();        
        for (Iterator<Resource> iterator = this.keySet().iterator(); iterator.hasNext();) {
			Resource resource = iterator.next();
			double weight = this.get(resource);            
            sb.append(resource.getLocalName()).append(" / ").append(weight).append("\n");
		}
        return sb.toString();
    }
}
